home *** CD-ROM | disk | FTP | other *** search
/ Linux Cubed Series 7: Sunsite / Linux Cubed Series 7 - Sunsite Vol 1.iso / system / admin / shadow-i.002 / shadow-i / shadow-ina-box-1.1 / Install < prev    next >
Text File  |  1996-07-30  |  10KB  |  335 lines

  1. #! /bin/sh
  2. #
  3. # Original install bash script done by Simone Chemelli <genius@dei.unipd.it>
  4. # 21/04/1996
  5. #
  6. # Script and package modifications done by Michael Quan <michael@envy.com>
  7. # June 13th, 1996
  8. #
  9. # Lines needed in order to modify 2 files ( /etc/inetd.conf and
  10. # /usr/X11R6/lib/X11/config/linux.cf ) to allow shadow correct compiling.
  11. #
  12.  
  13. echo "Modifying your /etc/inetd.conf for the new ftpd, pop3d, and xlockmore."
  14. echo "You may wish to verify the resulting /etc/inetd.conf as"
  15. echo "/etc/inetd.conf.orig"
  16. echo
  17. gcc -O2 modify.c -o modify
  18. modify
  19.  
  20. #
  21. # Lets now install the cracklib library from ftp.cert.org
  22. # md5sum = 47dd534919d034893ba25501e8bbf57d  cracklib25_small.tar.Z
  23. # There is no official md5sum from cert for this package.  I've created it
  24. # here locally.  You should verify for yourself.  -Michael"
  25. #
  26.  
  27. md5sum cracklib25_small.tar.Z
  28. echo
  29. echo "There is no official md5sum from cert for this package.  I've created it"
  30. echo "here locally.  You should verify for yourself."
  31. echo
  32. tar -xzf cracklib25_small.tar.Z
  33. echo "Moving the big dictionary file to /usr/local/lib directory"
  34. cp -f ./extras/pw_dict /usr/local/lib
  35. touch /usr/dict/words
  36. echo
  37. echo "Creating libcrack.a"
  38. echo
  39. cd ./cracklib25_small
  40. make all
  41. make install
  42. echo "Moving libcrack.a to /usr/lib"
  43. echo
  44. mv -f ./cracklib/libcrack.a /usr/lib/
  45. cd ../
  46.  
  47. #
  48. # Lines needed by shadow-960129.tar.gz from sunsite.unc.edu
  49. # md5sum = 45dd0995bb27ca4fd4dd4c866a15e095  shadow-960129.tar.gz
  50. # There is no official md5sum from sunsite.unc.edu for this package.
  51. # I've created it here locally.  You should verify for yourself.
  52. # -Michael
  53. #
  54.  
  55. md5sum shadow-960129.tar.gz
  56. echo
  57. echo "There is no official md5sum from sunsite.unc.edu for this package."
  58. echo "I've created it here locally.  You should verify for yourself."
  59. echo
  60. tar -xzf shadow-960129.tar.gz
  61. echo "Performing a few patches to enable libcrack.a and Linux release changes."
  62. echo
  63. cd ./shadow-960129
  64. cp -f Makefile.linux Makefile
  65. patch Makefile ../extras/Makefileshadow.patch
  66. cp -f config.h.linux config.h
  67. patch config.h ../extras/config.patch
  68. patch login.defs.linux ../extras/login.defs.patch
  69. mv -f login.defs.linux /etc/login.defs
  70. ln -s /usr/include/pwd.h pwd.h
  71. touch /etc/gshadow
  72. make all
  73. make install
  74. /usr/sbin/pwconv
  75. mv ./npasswd /etc/passwd
  76. mv ./nshadow /etc/shadow
  77. chmod a+r,og-w /etc/passwd*
  78. chmod o-r,og-w /etc/shadow*
  79. touch /var/adm/lastlog
  80. touch /var/adm/ftmp
  81. touch /var/adm/faillog
  82. touch /var/adm/sulog
  83. cd ../
  84. echo
  85.  
  86. #
  87. # Lines needed by wu-ftpd-2.4-fixed.tar.gz
  88. # md5sum = d6462af01cc4c19d50565dff0d7b6515  wu-ftpd-2.4-fixed.tar.gz
  89. # check against the checksums of sunsite.unc.edu under
  90. # pub/Linux/system/Network/file-transfer/wu-ftpd-2.4-CHECKSUMS
  91.  
  92. md5sum wu-ftpd-2.4-fixed.tar.gz
  93. echo
  94. echo "Check against the checksum value provided in the sunsite.unc.edu"
  95. echo "distribution for security peace of mind"
  96. echo
  97. tar -xzf wu-ftpd-2.4-fixed.tar.gz
  98. cd ./wu-ftpd-2.4-fixed
  99. echo "Creating <in_system.h> link as needed for wu-ftpd-2.4 package"
  100. ln -sf /usr/include/netinet/in_systm.h /usr/include/netinet/in_system.h
  101. echo
  102. echo "Enabling shadow passwords"
  103. patch ./src/makefiles/Makefile.lnx ../extras/Makeftpsrc.patch
  104. echo "Setting up ftp run directory."
  105. mkdir /usr/adm/ftpd
  106. echo "Building the ftpd binaries"
  107. build lnx
  108. echo
  109. echo "Stripping the ftpd binaries"
  110. strip ./bin/*
  111. echo
  112. echo "Performing a patch to ensure ftpd goes to /usr/sbin."
  113. echo
  114. patch Makefile ../extras/Makeftp.patch
  115. build install
  116. echo
  117. cd ../
  118.  
  119. # ** I see no reason for the below - Michael
  120. #----
  121. # Next lines are for users using CSH as default shell.
  122. # Comment them if you don't have csh and tcsh installed on your system.
  123.  
  124. #cat /etc/shells > /tmp/shells.tmp
  125. #echo "/bin/csh" >> /tmp/shells.tmp
  126. #cat /tmp/shells |sort |uniq > /tmp/shells
  127. #mv /tmp/shells /etc
  128. #ln -sf /bin/tcsh /bin/csh
  129. #----
  130.  
  131.  
  132. #
  133. # Lines needed by xlockmore-3.9.tar.gz from ftp.x.org
  134. # md5sum = 368dab072738f765896d6ce805d777e0  xlockmore-3.9.tar.gz
  135. # There is no official md5sum from ftp.x.org.  I've created it here
  136. # locally.  You should verify for yourself.  -Michael
  137. #
  138.  
  139. md5sum xlockmore-3.9.tar.gz
  140. echo
  141. echo "There is no official md5sum from ftp.x.org.  I've created it here"
  142. echo "locally.  You should verify for yourself."
  143. echo
  144. tar -xzf xlockmore-3.9.tar.gz
  145. cd ./xlockmore-3.9/
  146. echo "Performing a patch to enable shadow passwords and -lshadow."
  147. echo "Assuming you are using an ELF system.  Else, you must link with -lgdbm"
  148. echo
  149. patch Makefile.std ../extras/Makexlock.patch
  150. mv -f Makefile.std Makefile
  151. xmkmf
  152. make depend
  153. make
  154. strip ./xlock
  155. chmod 4755 ./xlock
  156. make install
  157. echo
  158. cd ../
  159.  
  160. #
  161. # Lines needed by xdm.tar.gz from sunsite.unc.edu
  162. # md5sum = 8b4bc8d70b686d112524b245b067eb78  xdm.tar.gz
  163. # There is no official md5sum from sunsite.unc.edu or the original
  164. # creator for this package.  I've created it here locally.  You should
  165. # verify for yourself.  -Michael
  166. #
  167.  
  168. md5sum xdm.tar.gz
  169. echo "There is no official md5sum from sunsite.unc.edu or the original"
  170. echo "creator for this package.  I've created it here locally.  You should"
  171. echo "verify for yourself."
  172. echo
  173. tar -xzf xdm.tar.gz
  174. cd ./xdm
  175. xmkmf
  176. make depend
  177. make
  178. strip ./xdm
  179. mv -f /usr/X11R6/bin/xdm /usr/X11R6/bin/xdm.old
  180. cp -f xdm /usr/X11R6/bin/
  181. cp -f xdm.man /usr/local/man/man1/xdm.1
  182. echo
  183. cd ..
  184.  
  185. #
  186. # Lines needed by sudo-1.2-shadow.tgz from sunsite.unc.edu
  187. # md5sum = fd2657e05002c4f6fa1026ddfe428685  sudo-1.2-shadow.tgz
  188. # There is no official md5sum from sunsite.unc.edu or the original
  189. # creator for this package.  I've created it here locally.  You should
  190. # verify for yourself.  -Michael
  191. #
  192.  
  193. echo
  194. md5sum sudo-1.2-shadow.tgz
  195. echo "There is no official md5sum from sunsite.unc.edu or the original"
  196. echo "creator for this package.  I've created it here locally.  You should"
  197. echo "verify for yourself."
  198. echo
  199. tar -xzf sudo-1.2-shadow.tgz
  200. cd ./sudo-1.2/
  201. echo "Enabling PARANOID settings."
  202. echo
  203. patch Makefile ../extras/Makefilesudo.patch
  204. make
  205. strip sudo.bin
  206. make install
  207. echo
  208. cd ../
  209.  
  210. #
  211. # Lines needed by adduser-shadow.pl from sunsite.unc.edu
  212. # md5sum = eeb0231a9a4a02a591a70c5f146f4788  adduser-shadow.pl
  213. # There is no official md5sum from sunsite.unc.edu.
  214. # I've created it here locally.  You should verify for yourself.  -Michael
  215. #
  216.  
  217. md5sum adduser-shadow.pl
  218. echo "There is no official md5sum from sunsite.unc.edu."
  219. echo "I've created it here locally.  You should verify for yourself."
  220. echo
  221. echo "Moving current /sbin/adduser to /sbin/adduser.old"
  222. mv /sbin/adduser /sbin/adduser.old
  223. echo "Copying adduser-shadow.pl to /sbin/adduser"
  224. cp -f ./adduser-shadow.pl /sbin/adduser
  225. echo
  226.  
  227. #
  228. # Lines needed by qpop2.2.tar.Z from ftp.qualcomm.com
  229. # md5sum = 687de4aa608119ac428146dd4e206bb5  qpop2.2.tgz
  230. # There is no official md5sum from ftp.qualcomm.com for qpop2.2.tar.Z
  231. # I've created it here locally.  You should verify for yourself.  -Michael
  232. #
  233.  
  234. md5sum qpop2.2.tgz
  235. echo "There is no official md5sum from ftp.qualcomm.com for qpop2.2.tar.Z"
  236. echo "I've created it here locally.  You should verify for yourself."
  237. echo
  238. tar -xzf qpop2.2.tgz
  239. cd ./qpopper2.2/
  240. echo "Enabling shadow passwords, pop mail authorization file, and pop mail"
  241. echo "bulletins.  Read ./qpopper2.2/README for more information."
  242. echo
  243. patch make.linux ../extras/Makepop.patch
  244. patch Makefile ../extras/MMakepop.patch
  245. echo "Creating /usr/spool/mail/popbulletins directory."
  246. echo
  247. mkdir /usr/spool/mail/popbulletins
  248. make linux
  249. mv -f ./popper.linux /usr/sbin/popper
  250. mv -f ./popauth /usr/sbin/
  251. make installman
  252. echo
  253. cd ../
  254.  
  255. #
  256. # Lines needed by imap-4.BETA.tar.Z from ftp.cac.washington.edu
  257. # md5sum = c2759c725294570d027526749e0d49fe  imap-4.BETA.tgz
  258. # There is no official md5sum from ftp.cac.washington.edu for imapd
  259. # I've created it here locally.  You should verify yourself.  -Michael
  260. #
  261.  
  262. md5sum imap-4.BETA.tgz
  263. echo "There is no official md5sum from ftp.cac.washington.edu for imapd"
  264. echo "I've created it here locally.  You should verify yourself."
  265. echo
  266. tar -xzf imap-4.BETA.tgz
  267. cd ./imap-4.BETA
  268. make slx
  269. strip ./imapd/imapd
  270. cp -f ./imapd/imapd /usr/sbin/in.imapd
  271. cp -f ./src/imapd/imapd.8c /usr/local/man/man8/imapd.8
  272. echo
  273. cd ..
  274.  
  275. #
  276. # Lines needed by pcnfsd.linux.tgz from sunsite.unc.edu
  277. # md5sum = 71b81ac3eab7da778155eaaca07f4d17  pcnfsd.linux.tgz
  278. # There is no official md5sum from SUN for pcnfsd.linux.tgz
  279. # I've created it here locally.  You should verify yourself.  -Michael
  280. #
  281.  
  282. md5sum pcnfsd.linux.tgz
  283. echo "There is no official md5sum from SUN for pcnfsd.linux.tgz"
  284. echo "I've created it here locally.  You should verify yourself."
  285. echo
  286. tar -xzf pcnfsd.linux.tgz
  287. cd ./pcnfsd
  288. echo "Enabling shadow passwords and user cache."
  289. echo
  290. patch common.h ../extras/pcnfsd.patch
  291. make linux
  292. cp pcnfsd.8c /usr/local/man/man8/pcnfsd.8
  293. strip ./linux/*.pcnfsd
  294. chmod go+rx ./linux/clnt.pcnfsd
  295. chmod o-x ./linux/rpc.pcnfsd
  296. mv -f /usr/sbin/clnt.pcnfsd /usr/sbin/clnt.pcnfsd.old
  297. mv -f /usr/sbin/rpc.pcnfsd /usr/sbin/rpc.pcnfsd.old
  298. mv -f ./linux/*.pcnfsd /usr/sbin/
  299. echo
  300. cd ..
  301.  
  302. #
  303. # Lines needed by bwnfsd.tar.gz from ftp.acs.com
  304. # md5sum = 2beafd723b19775314b6f553c40caab5  bwnfsd.tar.gz
  305. # There is no official md5sum for this package.
  306. # I've created it here locally.  You should verify yourself.  -Michael
  307. #
  308.  
  309. md5sum bwnfsd.tar.gz
  310. echo "There is no official md5sum for this package."
  311. echo "I've created it here locally.  You should verify yourself."
  312. echo
  313. tar -xzf bwnfsd.tar.gz
  314. cd ./bwnfsd
  315. echo "Enabling shadow passwords."
  316. echo
  317. patch bwnfsd.c ../extras/bwnfsd.patch
  318. patch Makefile ../extras/Makebwnfs.patch
  319. make linux
  320. strip bwnfsd
  321. chmod o-x bwnfsd
  322. mv -f /usr/sbin/rpc.bwnfsd /usr/sbin/rpc.bwnfsd.old
  323. mv -f bwnfsd /usr/sbin/rpc.bwnfsd
  324. echo
  325. cd ..
  326.  
  327. # Confirm the end
  328.  
  329. echo
  330. echo " The installation of shadow passwords suite is finished."
  331. echo " Try it out now. "
  332. echo
  333.  
  334. # end of script
  335.